﻿<UserControl x:Class="P2.Cuberry.Modules.SimpleSCM.SCProduct.SCProductsListView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    >


    <UserControl.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <ResourceDictionary Source="/P2.Cuberry.Framework.Layout;component/Styles/Styles.xaml"/>
                <ResourceDictionary Source="/P2.Cuberry.Framework.Layout;component/Styles/CuberryDataGrid.xaml"/>
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </UserControl.Resources>

    
    <Grid VerticalAlignment="Stretch">
        <Grid.RowDefinitions>
            <RowDefinition Height="*" MinHeight="44" />            
 
        </Grid.RowDefinitions>

        <DataGrid Grid.Row ="0" ItemsSource="{Binding}" 
                     Name="SCProductsList" 
                     SelectionChanged="SCProductsList_SelectionChanged" 
                     MouseDoubleClick="SCProductsList_DblClick"                                              
                     Style="{DynamicResource CuberryDataGridStyle}"
                     VerticalAlignment="Stretch" >
            
            <DataGrid.Columns>
                <DataGridTextColumn Header="{Translate FiAccountNoL}" Binding="{Binding Path=FiAccountNo}" MinWidth="25" Width="100" />
                <DataGridTextColumn Header="{Translate PersonTitleID}" Binding="{Binding Path=PersonTitleName}" MinWidth="25" Width="100" />
                
                <DataGridTextColumn Header="{Translate ProductNameEnL}" Binding="{Binding Path=ProductNameEn}" MinWidth="25" Width="120" />
                <DataGridTextColumn Header="{Translate ProductNameDeL}" Binding="{Binding Path=ProductNameDe}" MinWidth="25" Width="120" />
                <DataGridTextColumn Header="{Translate ProductNameArL}" Binding="{Binding Path=ProductNameAr}" MinWidth="25" Width="120" />
                
                <DataGridTextColumn Header="{Translate DescriptionL}" Binding="{Binding Path=Description}" MinWidth="25" Width="120" />
                <DataGridTextColumn Header="{Translate PurchaseUnitEANL}" Binding="{Binding Path=PurchaseUnitEAN}" MinWidth="25" Width="120" />
                <DataGridTextColumn Header="{Translate SellingUnitEANL}" Binding="{Binding Path=SellingUnitEAN}" MinWidth="25" Width="120" />
                
                <DataGridTextColumn Header="{Translate DateOfBirthL}" Binding="{Binding Path=DateOfBirth, StringFormat=dd/MM/yyyy}" MinWidth="40" Width="100" />                 
                <DataGridTextColumn Header="{Translate StatusNameL}" Binding="{Binding Path=StatusName, Mode=OneWay}" MinWidth="40" Width="*" IsReadOnly="True" />
                

            </DataGrid.Columns>
        </DataGrid>
    
</Grid>
</UserControl>
